package com.hfstu.framework.core.utils.web.dwr;


import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;

import org.directwebremoting.ScriptSession;
import org.directwebremoting.WebContext;
import org.directwebremoting.WebContextFactory;

public class DwrUtil {

	public static HttpServletRequest getRequest(){
		WebContext webContext = WebContextFactory.get();  
		return webContext.getHttpServletRequest();
		
	}
	
	public static HttpSession getSession(){
		WebContext webContext = WebContextFactory.get();  
		return webContext.getSession();
		
	}
	
	public static ScriptSession getScriptSession(){
		WebContext webContext = WebContextFactory.get();  
		return webContext.getScriptSession();
		
	}
}
